package com.guet.careapp.common;

import com.guet.careapp.utils.PropertyUtil;

/**
 * Created by LXM on 2017/10/27.
 *
 * @author LXM
 * @version 1.0
 * @description 用于存储常量的类
 * @datetime 16:56
 */
public class Constants {

  public static final String propertyFile = "error-meanning";
  public static final String jpushFile = "jpush-config";
  public static final String aliyunFile = "aliyun-config";
  public static final PropertyUtil propertyUtil = PropertyUtil.getInstance(propertyFile);
  public static final PropertyUtil jpushUtil = PropertyUtil.getInstance(jpushFile);
  public static final PropertyUtil aliyunUtil = PropertyUtil.getInstance(aliyunFile);
  /**
   * 错误代码.
   */
  public static final String SUCCESS_CODE = propertyUtil.getProperty("success-code");
  public static final String SUCCESS = propertyUtil.getProperty("success");

  public static final String FAIL_CODE = propertyUtil.getProperty("fail-code");
  public static final String FAIL = propertyUtil.getProperty("fail");

  public static final String UNKNOWN_CODE = propertyUtil.getProperty("unknown-code");
  public static final String UNKNOWN = propertyUtil.getProperty("unknown");

  public static final String NOTFIND_CODE = propertyUtil.getProperty("notfind-code");
  public static final String NOTFIND = propertyUtil.getProperty("notfind");

  public static final String TYPE_ERROR_CODE = propertyUtil.getProperty("type-convert-code");
  public static final String TYPE_ERROR = propertyUtil.getProperty("type-convert");

  public static final String EXIST_ERROR_CODE = propertyUtil.getProperty("exist-code");
  public static final String EXIST_ERROR = propertyUtil.getProperty("exist");

  public static final String ISBLANK_CODE = propertyUtil.getProperty("isblank-code");
  public static final String ISBLANK = propertyUtil.getProperty("isblank");

  public static final String TIMEOUT_CODE = propertyUtil.getProperty("timeout-code");
  public static final String TIMEOUT = propertyUtil.getProperty("timeout");

  public static final String INVAILD_CODE = propertyUtil.getProperty("invalid-code");
  public static final String INVAILD = propertyUtil.getProperty("invalid");



  /**
   * JPush的应用
   */
  public static final String APP_KEY = jpushUtil.getProperty("APP_KEY");
  public static final String MASTER_SECRET=jpushUtil.getProperty("MASTER_SECRET");
  public static final String JPUSH_HOST = jpushUtil.getProperty("host");

  /**
   * 传输JSON
   */
  public static final String APPLICATION_JSON = "application/json";
  public static final String CONTENT_TYPE_TEXT_JSON = "text/json";

  /**
   * 文件上传路径
   */
  public static final String UPLOAD_PATH = "service\\emergency\\voice";


  /***
   * 阿里云的变量汇总
   */

  public static final String SIGN_NAME=aliyunUtil.getProperty("signName");
  public static final String DRUG_TEMPLATE=aliyunUtil.getProperty("drupTemplateName");
  public static final String TUMBLE_TEMPLATE=aliyunUtil.getProperty("tumbleTemplateName");
  public static final String VERIFY_TEMPLATE=aliyunUtil.getProperty("smsVerifyCodeTemplateName");

  /***
   * 缓存时间
   */
  public static final Long CACHE_TIMETOLIVE=6000000L;



}
